home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gigarom 1
/
Gigarom Macintosh Archives (Quantum Leap)(CDRM1080320)(1993).iso
/
FILES
/
APP
/
S-Z
/
The Regulator.cpt
/
The Regulator source
/
XPRAM.h
< prev
Wrap
Text File
|
1992-06-19
|
1KB
|
40 lines
/* Extended Parameter RAM locations
**
** of course, any of these can change at any time, and they aren't official
** nor from Apple. I figured these out by disassembling code. This stuff WILL
** change in the future. Don't base any products on this, or you'll be very
** sorry (and DTS will laugh in your face…) Don't ask Apple for help on this
** stuff… they have no further information they are willing to disclose.
*/
#define PRAM_BASE 0x70
#define prSysSleep_Offset 0x00
#define prHDSleep_Offset 0x01
#define prFlags_Offset 0x02
#define prFlags_Offset_Portable 0x07
#define kPowerSave 0x01 /* mask in prFlags */
/* Inline routines */
pascal void SetPRAM(short loc, short numBytes, char* valPtr)={0x205F,0x201F,0xA052};
/*
move.l (sp)+,d0 ; write x bytes at given location
move.l (sp)+,a0 ; a0 points at data
_WriteXPRam
*/
pascal void ReadPRAM(short loc, short numBytes, char* valPtr)={0x205F,0x201F,0xA051};
/*
move.l (sp)+,d0 ; read x bytes at given location
move.l (sp)+,a0 ; a0 points at data
_ReadXPRam
*/
/* from PowerMgr.h */
/* access to Power Manager's local variables */
#define PMgrLBase 0xd18
#define PMgrLocal(offset) (*((char *)(*((long *)PMgrLBase)+(offset))))
#define TOdirtyFlag 0x11